import 'package:WebTest/chooseFood/ui/pages/main/initialize_items.dart';
import 'package:flutter/material.dart';

class BDMainScreen extends StatefulWidget {
  static final String routerName = "/";
  @override
  _BDMainScreenState createState() => _BDMainScreenState();
}

class _BDMainScreenState extends State<BDMainScreen> {
  int _currentIndex = 0;
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: IndexedStack(
        index: _currentIndex,
        children: pages,
      ),
      bottomNavigationBar: BottomNavigationBar(
//        backgroundColor: Colors.white,
        currentIndex: _currentIndex,
        items: items,
        onTap: (index){
          setState(() {
            _currentIndex = index;
          });
        },
      ),
    );
  }
}
